#include<bits/stdc++.h>
#include"../Quicksort.hpp"
using namespace std;

vector<int> data1,data2,data3;

int main(){
    clock_t start1,end1,start2,end2,start3,end3;
    ios::sync_with_stdio(false);
    int n,x;
    cin>>n;
    for(int i=0;i<n;i++){
        cin>>x;
        data1.push_back(x);
        data2.push_back(x);
        data3.push_back(x);
    }

    start1=clock();
    sort_MoT(data1);
    end1=clock();

    start2=clock();
    sort_random(data2);
    end2=clock();

    start3=clock();
    sort_average(data3);
    end3=clock();

    cout<<"The using time with MoT strategy is: "<<end1-start1<<" ms."<<endl;
    cout<<"And the using time with random strategy is: "<<end2-start2<<" ms"<<endl;
    cout<<"And the using time with average strategy is: "<<end3-start3<<" ms"<<endl;
}